home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1999 July: Mac OS SDK / Dev.CD Jul 99 SDK1.toast / Development Kits / Mac OS / Interfaces&Libraries / Universal / Interfaces / AIncludes / SoundSprocket.a < prev    next >
Encoding:
Text File  |  1998-08-17  |  17.8 KB  |  531 lines  |  [TEXT/MPS ]

  1. ;
  2. ;    File:        SoundSprocket.a
  3. ;
  4. ;    Contains:    Games Sprockets: SoundSprocket interfaces
  5. ;
  6. ;    Version:    Technology:    NetSprocket 1.0
  7. ;                Release:    Universal Interfaces 3.2
  8. ;
  9. ;    Copyright:    © 1996-1998 by Apple Computer, Inc., all rights reserved.
  10. ;
  11. ;    Bugs?:        For bug reports, consult the following page on
  12. ;                the World Wide Web:
  13. ;
  14. ;                    http://developer.apple.com/bugreporter/
  15. ;
  16. ;
  17.     IF &TYPE('__SOUNDSPROCKET__') = 'UNDEFINED' THEN
  18. __SOUNDSPROCKET__ SET 1
  19.  
  20.     IF &TYPE('__MACTYPES__') = 'UNDEFINED' THEN
  21.     include 'MacTypes.a'
  22.     ENDIF
  23.     IF &TYPE('__EVENTS__') = 'UNDEFINED' THEN
  24.     include 'Events.a'
  25.     ENDIF
  26.     IF &TYPE('__QD3D__') = 'UNDEFINED' THEN
  27.     include 'QD3D.a'
  28.     ENDIF
  29.     IF &TYPE('__QD3DCAMERA__') = 'UNDEFINED' THEN
  30.     include 'QD3DCamera.a'
  31.     ENDIF
  32.  
  33. ; *******************************************************************************
  34. ; *    This stuff will be moved to Errors.h in a subsequent release
  35. ; *****************************************************************************
  36.  
  37.  
  38. kSSpInternalErr                    EQU        -30340
  39. kSSpVersionErr                    EQU        -30341
  40. kSSpCantInstallErr                EQU        -30342
  41. kSSpParallelUpVectorErr            EQU        -30343
  42. kSSpScaleToZeroErr                EQU        -30344
  43.  
  44. ; *******************************************************************************
  45. ; *    SndSetInfo/SndGetInfo Messages
  46. ; *****************************************************************************
  47.  
  48. ;     The siSSpCPULoadLimit = '3dll' selector for SndGetInfo fills in a value of    
  49. ;     type UInt32.                                                                
  50.  
  51.  
  52. kSSpSpeakerKind_Stereo            EQU        0
  53. kSSpSpeakerKind_Mono            EQU        1
  54. kSSpSpeakerKind_Headphones        EQU        2
  55.  
  56. ;     This is the data type is used with the SndGet/SetInfo selector                
  57. ;     siSSpSpeakerSetup = '3dst'                                                    
  58. SSpSpeakerSetupData        RECORD 0
  59. speakerKind                 ds.l    1                ; offset: $0 (0)        ;  Speaker configuration                
  60. speakerAngle             ds        Float32            ; offset: $4 (4)        ;  Angle formed by user and speakers    
  61. reserved0                 ds.l    1                ; offset: $8 (8)        ;  Reserved for future use -- set to 0    
  62. reserved1                 ds.l    1                ; offset: $C (12)        ;  Reserved for future use -- set to 0    
  63. sizeof                     EQU *                    ; size:   $10 (16)
  64.                         ENDR
  65.  
  66. kSSpMedium_Air                    EQU        0
  67. kSSpMedium_Water                EQU        1
  68.  
  69.  
  70. kSSpSourceMode_Unfiltered        EQU        0                    ; No filtering applied                    
  71. kSSpSourceMode_Localized        EQU        1                    ; Localized by source position            
  72. kSSpSourceMode_Ambient            EQU        2                    ; Coming from all around                
  73. kSSpSourceMode_Binaural            EQU        3                    ; Already binaurally localized            
  74.  
  75. SSpLocationData            RECORD 0
  76. elevation                 ds        Float32            ; offset: $0 (0)        ;  Angle of the meridian -- pos is up    
  77. azimuth                     ds        Float32            ; offset: $4 (4)        ;  Angle of the parallel -- pos is left    
  78. distance                 ds        Float32            ; offset: $8 (8)        ;  Distance between source and listener    
  79. projectionAngle             ds        Float32            ; offset: $C (12)        ;  Cos(angle) between cone and listener    
  80. sourceVelocity             ds        Float32            ; offset: $10 (16)        ;  Speed of source toward the listener    
  81. listenerVelocity         ds        Float32            ; offset: $14 (20)        ; Speed of listener toward the source    
  82. sizeof                     EQU *                    ; size:   $18 (24)
  83.                         ENDR
  84. SSpVirtualSourceData    RECORD 0
  85. attenuation                 ds        Float32            ; offset: $0 (0)        ;  Attenuation factor                    
  86. location                 ds        SSpLocationData ; offset: $4 (4)        ;  Location of virtual source            
  87. sizeof                     EQU *                    ; size:   $1C (28)
  88.                         ENDR
  89. ;     This is the data type is used with the SndGet/SetInfo selector                
  90. ;     siSSpLocalization = '3dif'                                                    
  91. SSpLocalizationData        RECORD 0
  92. cpuLoad                     ds.l    1                ; offset: $0 (0)        ;  CPU load vs. quality -- 0 is best    
  93. medium                     ds.l    1                ; offset: $4 (4)        ;  Medium for sound propagation            
  94. humidity                 ds        Float32            ; offset: $8 (8)        ;  Humidity when medium is air            
  95. roomSize                 ds        Float32            ; offset: $C (12)        ;  Reverb model -- distance bet. walls    
  96. roomReflectivity         ds        Float32            ; offset: $10 (16)        ; Reverb model -- bounce attenuation    
  97. reverbAttenuation         ds        Float32            ; offset: $14 (20)        ; Reverb model -- mix level            
  98. sourceMode                 ds.l    1                ; offset: $18 (24)        ;  Type of filtering to apply            
  99. referenceDistance         ds        Float32            ; offset: $1C (28)        ; Nominal distance for recording        
  100. coneAngleCos             ds        Float32            ; offset: $20 (32)        ;  Cos(angle/2) of attenuation cone        
  101. coneAttenuation             ds        Float32            ; offset: $24 (36)        ;  Attenuation outside the cone            
  102. currentLocation             ds        SSpLocationData ; offset: $28 (40)        ;  Location of the sound                 
  103. reserved0                 ds.l    1                ; offset: $40 (64)        ;  Reserved for future use -- set to 0    
  104. reserved1                 ds.l    1                ; offset: $44 (68)        ;  Reserved for future use -- set to 0    
  105. reserved2                 ds.l    1                ; offset: $48 (72)        ;  Reserved for future use -- set to 0    
  106. reserved3                 ds.l    1                ; offset: $4C (76)        ;  Reserved for future use -- set to 0    
  107. virtualSourceCount         ds.l    1                ; offset: $50 (80)        ; Number of reflections                
  108. virtualSource             ds.b    4 * SSpVirtualSourceData.sizeof ; offset: $54 (84) ; The reflections                        
  109. sizeof                     EQU *                    ; size:   $C4 (196)
  110.                         ENDR
  111.     IF TARGET_CPU_PPC THEN
  112. ; *******************************************************************************
  113. ; *    Global functions
  114. ; *****************************************************************************
  115.  
  116. ;
  117. ; extern OSStatus SSpConfigureSpeakerSetup(SSpEventProcPtr inEventProcPtr)
  118. ;
  119.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  120.         IMPORT_CFM_FUNCTION SSpConfigureSpeakerSetup
  121.     ENDIF
  122.  
  123. ;
  124. ; extern OSStatus SSpGetCPULoadLimit(UInt32 *outCPULoadLimit)
  125. ;
  126.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  127.         IMPORT_CFM_FUNCTION SSpGetCPULoadLimit
  128.     ENDIF
  129.  
  130.  
  131. ; *******************************************************************************
  132. ; *    Routines for Maniulating Listeners
  133. ; *****************************************************************************
  134.  
  135.  
  136.  
  137. ;
  138. ; extern OSStatus SSpListener_New(SSpListenerReference *outListenerReference)
  139. ;
  140.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  141.         IMPORT_CFM_FUNCTION SSpListener_New
  142.     ENDIF
  143.  
  144. ;
  145. ; extern OSStatus SSpListener_Dispose(SSpListenerReference inListenerReference)
  146. ;
  147.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  148.         IMPORT_CFM_FUNCTION SSpListener_Dispose
  149.     ENDIF
  150.  
  151. ;
  152. ; extern OSStatus SSpListener_SetTransform(SSpListenerReference inListenerReference, const TQ3Matrix4x4 *inTransform)
  153. ;
  154.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  155.         IMPORT_CFM_FUNCTION SSpListener_SetTransform
  156.     ENDIF
  157.  
  158. ;
  159. ; extern OSStatus SSpListener_GetTransform(SSpListenerReference inListenerReference, TQ3Matrix4x4 *outTransform)
  160. ;
  161.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  162.         IMPORT_CFM_FUNCTION SSpListener_GetTransform
  163.     ENDIF
  164.  
  165. ;
  166. ; extern OSStatus SSpListener_SetPosition(SSpListenerReference inListenerReference, const TQ3Point3D *inPosition)
  167. ;
  168.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  169.         IMPORT_CFM_FUNCTION SSpListener_SetPosition
  170.     ENDIF
  171.  
  172. ;
  173. ; extern OSStatus SSpListener_GetPosition(SSpListenerReference inListenerReference, TQ3Point3D *outPosition)
  174. ;
  175.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  176.         IMPORT_CFM_FUNCTION SSpListener_GetPosition
  177.     ENDIF
  178.  
  179. ;
  180. ; extern OSStatus SSpListener_SetOrientation(SSpListenerReference inListenerReference, const TQ3Vector3D *inOrientation)
  181. ;
  182.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  183.         IMPORT_CFM_FUNCTION SSpListener_SetOrientation
  184.     ENDIF
  185.  
  186. ;
  187. ; extern OSStatus SSpListener_GetOrientation(SSpListenerReference inListenerReference, TQ3Vector3D *outOrientation)
  188. ;
  189.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  190.         IMPORT_CFM_FUNCTION SSpListener_GetOrientation
  191.     ENDIF
  192.  
  193. ;
  194. ; extern OSStatus SSpListener_SetUpVector(SSpListenerReference inListenerReference, const TQ3Vector3D *inUpVector)
  195. ;
  196.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  197.         IMPORT_CFM_FUNCTION SSpListener_SetUpVector
  198.     ENDIF
  199.  
  200. ;
  201. ; extern OSStatus SSpListener_GetUpVector(SSpListenerReference inListenerReference, TQ3Vector3D *outUpVector)
  202. ;
  203.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  204.         IMPORT_CFM_FUNCTION SSpListener_GetUpVector
  205.     ENDIF
  206.  
  207. ;
  208. ; extern OSStatus SSpListener_SetCameraPlacement(SSpListenerReference inListenerReference, const TQ3CameraPlacement *inCameraPlacement)
  209. ;
  210.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  211.         IMPORT_CFM_FUNCTION SSpListener_SetCameraPlacement
  212.     ENDIF
  213.  
  214. ;
  215. ; extern OSStatus SSpListener_GetCameraPlacement(SSpListenerReference inListenerReference, TQ3CameraPlacement *outCameraPlacement)
  216. ;
  217.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  218.         IMPORT_CFM_FUNCTION SSpListener_GetCameraPlacement
  219.     ENDIF
  220.  
  221. ;
  222. ; extern OSStatus SSpListener_SetVelocity(SSpListenerReference inListenerReference, const TQ3Vector3D *inVelocity)
  223. ;
  224.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  225.         IMPORT_CFM_FUNCTION SSpListener_SetVelocity
  226.     ENDIF
  227.  
  228. ;
  229. ; extern OSStatus SSpListener_GetVelocity(SSpListenerReference inListenerReference, TQ3Vector3D *outVelocity)
  230. ;
  231.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  232.         IMPORT_CFM_FUNCTION SSpListener_GetVelocity
  233.     ENDIF
  234.  
  235. ;
  236. ; extern OSStatus SSpListener_GetActualVelocity(SSpListenerReference inListenerReference, TQ3Vector3D *outVelocity)
  237. ;
  238.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  239.         IMPORT_CFM_FUNCTION SSpListener_GetActualVelocity
  240.     ENDIF
  241.  
  242. ;
  243. ; extern OSStatus SSpListener_SetMedium(SSpListenerReference inListenerReference, UInt32 inMedium, float inHumidity)
  244. ;
  245.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  246.         IMPORT_CFM_FUNCTION SSpListener_SetMedium
  247.     ENDIF
  248.  
  249. ;
  250. ; extern OSStatus SSpListener_GetMedium(SSpListenerReference inListenerReference, UInt32 *outMedium, float *outHumidity)
  251. ;
  252.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  253.         IMPORT_CFM_FUNCTION SSpListener_GetMedium
  254.     ENDIF
  255.  
  256. ;
  257. ; extern OSStatus SSpListener_SetReverb(SSpListenerReference inListenerReference, float inRoomSize, float inRoomReflectivity, float inReverbAttenuation)
  258. ;
  259.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  260.         IMPORT_CFM_FUNCTION SSpListener_SetReverb
  261.     ENDIF
  262.  
  263. ;
  264. ; extern OSStatus SSpListener_GetReverb(SSpListenerReference inListenerReference, float *outRoomSize, float *outRoomReflectivity, float *outReverbAttenuation)
  265. ;
  266.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  267.         IMPORT_CFM_FUNCTION SSpListener_GetReverb
  268.     ENDIF
  269.  
  270. ;
  271. ; extern OSStatus SSpListener_SetMetersPerUnit(SSpListenerReference inListenerReference, float inMetersPerUnit)
  272. ;
  273.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  274.         IMPORT_CFM_FUNCTION SSpListener_SetMetersPerUnit
  275.     ENDIF
  276.  
  277. ;
  278. ; extern OSStatus SSpListener_GetMetersPerUnit(SSpListenerReference inListenerReference, float *outMetersPerUnit)
  279. ;
  280.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  281.         IMPORT_CFM_FUNCTION SSpListener_GetMetersPerUnit
  282.     ENDIF
  283.  
  284.  
  285. ; *******************************************************************************
  286. ; *    Routines for Manipulating Sources
  287. ; *****************************************************************************
  288.  
  289.  
  290.  
  291. ;
  292. ; extern OSStatus SSpSource_New(SSpSourceReference *outSourceReference)
  293. ;
  294.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  295.         IMPORT_CFM_FUNCTION SSpSource_New
  296.     ENDIF
  297.  
  298. ;
  299. ; extern OSStatus SSpSource_Dispose(SSpSourceReference inSourceReference)
  300. ;
  301.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  302.         IMPORT_CFM_FUNCTION SSpSource_Dispose
  303.     ENDIF
  304.  
  305. ;
  306. ; extern OSStatus SSpSource_CalcLocalization(SSpSourceReference inSourceReference, SSpListenerReference inListenerReference, SSpLocalizationData *out3DInfo)
  307. ;
  308.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  309.         IMPORT_CFM_FUNCTION SSpSource_CalcLocalization
  310.     ENDIF
  311.  
  312. ;
  313. ; extern OSStatus SSpSource_SetTransform(SSpSourceReference inSourceReference, const TQ3Matrix4x4 *inTransform)
  314. ;
  315.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  316.         IMPORT_CFM_FUNCTION SSpSource_SetTransform
  317.     ENDIF
  318.  
  319. ;
  320. ; extern OSStatus SSpSource_GetTransform(SSpSourceReference inSourceReference, TQ3Matrix4x4 *outTransform)
  321. ;
  322.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  323.         IMPORT_CFM_FUNCTION SSpSource_GetTransform
  324.     ENDIF
  325.  
  326. ;
  327. ; extern OSStatus SSpSource_SetPosition(SSpSourceReference inSourceReference, const TQ3Point3D *inPosition)
  328. ;
  329.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  330.         IMPORT_CFM_FUNCTION SSpSource_SetPosition
  331.     ENDIF
  332.  
  333. ;
  334. ; extern OSStatus SSpSource_GetPosition(SSpSourceReference inSourceReference, TQ3Point3D *outPosition)
  335. ;
  336.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  337.         IMPORT_CFM_FUNCTION SSpSource_GetPosition
  338.     ENDIF
  339.  
  340. ;
  341. ; extern OSStatus SSpSource_SetOrientation(SSpSourceReference inSourceReference, const TQ3Vector3D *inOrientation)
  342. ;
  343.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  344.         IMPORT_CFM_FUNCTION SSpSource_SetOrientation
  345.     ENDIF
  346.  
  347. ;
  348. ; extern OSStatus SSpSource_GetOrientation(SSpSourceReference inSourceReference, TQ3Vector3D *outOrientation)
  349. ;
  350.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  351.         IMPORT_CFM_FUNCTION SSpSource_GetOrientation
  352.     ENDIF
  353.  
  354. ;
  355. ; extern OSStatus SSpSource_SetUpVector(SSpSourceReference inSourceReference, const TQ3Vector3D *inUpVector)
  356. ;
  357.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  358.         IMPORT_CFM_FUNCTION SSpSource_SetUpVector
  359.     ENDIF
  360.  
  361. ;
  362. ; extern OSStatus SSpSource_GetUpVector(SSpSourceReference inSourceReference, TQ3Vector3D *outUpVector)
  363. ;
  364.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  365.         IMPORT_CFM_FUNCTION SSpSource_GetUpVector
  366.     ENDIF
  367.  
  368. ;
  369. ; extern OSStatus SSpSource_SetCameraPlacement(SSpSourceReference inSourceReference, const TQ3CameraPlacement *inCameraPlacement)
  370. ;
  371.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  372.         IMPORT_CFM_FUNCTION SSpSource_SetCameraPlacement
  373.     ENDIF
  374.  
  375. ;
  376. ; extern OSStatus SSpSource_GetCameraPlacement(SSpSourceReference inSourceReference, TQ3CameraPlacement *outCameraPlacement)
  377. ;
  378.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  379.         IMPORT_CFM_FUNCTION SSpSource_GetCameraPlacement
  380.     ENDIF
  381.  
  382. ;
  383. ; extern OSStatus SSpSource_SetVelocity(SSpSourceReference inSourceReference, const TQ3Vector3D *inVelocity)
  384. ;
  385.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  386.         IMPORT_CFM_FUNCTION SSpSource_SetVelocity
  387.     ENDIF
  388.  
  389. ;
  390. ; extern OSStatus SSpSource_GetVelocity(SSpSourceReference inSourceReference, TQ3Vector3D *outVelocity)
  391. ;
  392.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  393.         IMPORT_CFM_FUNCTION SSpSource_GetVelocity
  394.     ENDIF
  395.  
  396. ;
  397. ; extern OSStatus SSpSource_GetActualVelocity(SSpSourceReference inSourceReference, TQ3Vector3D *outVelocity)
  398. ;
  399.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  400.         IMPORT_CFM_FUNCTION SSpSource_GetActualVelocity
  401.     ENDIF
  402.  
  403. ;
  404. ; extern OSStatus SSpSource_SetCPULoad(SSpSourceReference inSourceReference, UInt32 inCPULoad)
  405. ;
  406.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  407.         IMPORT_CFM_FUNCTION SSpSource_SetCPULoad
  408.     ENDIF
  409.  
  410. ;
  411. ; extern OSStatus SSpSource_GetCPULoad(SSpSourceReference inSourceReference, UInt32 *outCPULoad)
  412. ;
  413.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  414.         IMPORT_CFM_FUNCTION SSpSource_GetCPULoad
  415.     ENDIF
  416.  
  417. ;
  418. ; extern OSStatus SSpSource_SetMode(SSpSourceReference inSourceReference, UInt32 inMode)
  419. ;
  420.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  421.         IMPORT_CFM_FUNCTION SSpSource_SetMode
  422.     ENDIF
  423.  
  424. ;
  425. ; extern OSStatus SSpSource_GetMode(SSpSourceReference inSourceReference, UInt32 *outMode)
  426. ;
  427.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  428.         IMPORT_CFM_FUNCTION SSpSource_GetMode
  429.     ENDIF
  430.  
  431. ;
  432. ; extern OSStatus SSpSource_SetReferenceDistance(SSpSourceReference inSourceReference, float inReferenceDistance)
  433. ;
  434.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  435.         IMPORT_CFM_FUNCTION SSpSource_SetReferenceDistance
  436.     ENDIF
  437.  
  438. ;
  439. ; extern OSStatus SSpSource_GetReferenceDistance(SSpSourceReference inSourceReference, float *outReferenceDistance)
  440. ;
  441.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  442.         IMPORT_CFM_FUNCTION SSpSource_GetReferenceDistance
  443.     ENDIF
  444.  
  445. ;
  446. ; extern OSStatus SSpSource_SetSize(SSpSourceReference inSourceReference, float inLength, float inWidth, float inHeight)
  447. ;
  448.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  449.         IMPORT_CFM_FUNCTION SSpSource_SetSize
  450.     ENDIF
  451.  
  452. ;
  453. ; extern OSStatus SSpSource_GetSize(SSpSourceReference inSourceReference, float *outLength, float *outWidth, float *outHeight)
  454. ;
  455.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  456.         IMPORT_CFM_FUNCTION SSpSource_GetSize
  457.     ENDIF
  458.  
  459. ;
  460. ; extern OSStatus SSpSource_SetAngularAttenuation(SSpSourceReference inSourceReference, float inConeAngle, float inConeAttenuation)
  461. ;
  462.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  463.         IMPORT_CFM_FUNCTION SSpSource_SetAngularAttenuation
  464.     ENDIF
  465.  
  466. ;
  467. ; extern OSStatus SSpSource_GetAngularAttenuation(SSpSourceReference inSourceReference, float *outConeAngle, float *outConeAttenuation)
  468. ;
  469.     IF TARGET_OS_MAC ** TARGET_RT_MAC_CFM THEN
  470.         IMPORT_CFM_FUNCTION SSpSource_GetAngularAttenuation
  471.     ENDIF
  472.  
  473.     ENDIF    ; TARGET_CPU_PPC
  474.  
  475. ; *******************************************************************************
  476. ; *    MORE LATE-BREAKING NEWS
  477. ; *
  478. ; *    The SndGetInfo selector siSSpFilterVersion and datatype SSpFilterVersionData
  479. ; *    have been removed in favor of an alternate way of accessing filter version
  480. ; *    information.  The following function may be used for this purpose.
  481. ; *******************************************************************************
  482. ;// **************************** GetSSpFilterVersion ****************************
  483. ;// Finds the manufacturer and version number of the SoundSprocket filter that
  484. ;// may be installed.  inManufacturer should be the manufacturer code specified
  485. ;// at the installation time, which may be zero to allow any manufacturer.
  486. ;// If no error is encountered, outManufacturer is set to the actual manufacturer
  487. ;// code and outMajorVersion and outMinorVersion are set to the component
  488. ;// specification level and manufacturer's implementation revision, respectively.
  489. ;OSStatus GetSSpFilterVersion(
  490. ;    OSType                    inManufacturer,
  491. ;    OSType*                    outManufacturer,
  492. ;    UInt32*                    outMajorVersion,
  493. ;    UInt32*                    outMinorVersion)
  494. ;{
  495. ;    OSStatus                err;
  496. ;    ComponentDescription    description;
  497. ;    Component                componentRef;
  498. ;    UInt32                    vers;
  499. ;    
  500. ;    // Set up the component description
  501. ;    description.componentType            = kSoundEffectsType;
  502. ;    description.componentSubType        = kSSpLocalizationSubType;
  503. ;    description.componentManufacturer    = inManufacturer;
  504. ;    description.componentFlags            = 0;        
  505. ;    description.componentFlagsMask        = 0;    
  506. ;    
  507. ;    // Find a component matching the description
  508. ;    componentRef = FindNextComponent(nil, &description);
  509. ;    if (componentRef == nil)  return couldntGetRequiredComponent;
  510. ;    
  511. ;    // Get the component description (for the manufacturer code)
  512. ;    err = GetComponentInfo(componentRef, &description, nil, nil, nil);
  513. ;    if (err != noErr)  return err;
  514. ;    
  515. ;    // Get the version composite
  516. ;    vers = (UInt32) GetComponentVersion((ComponentInstance) componentRef);
  517. ;    
  518. ;    // Return the results
  519. ;    *outManufacturer = description.componentManufacturer;
  520. ;    *outMajorVersion = HiWord(vers);
  521. ;    *outMinorVersion = LoWord(vers);
  522. ;    
  523. ;    return noErr;
  524. ;}
  525. ;******************************************************************************
  526.  
  527.  
  528.  
  529.     ENDIF ; __SOUNDSPROCKET__ 
  530.  
  531.